package com.chenxin.dubbo.service.impl;

import com.chenxin.dubbo.entity.Bean;
import com.chenxin.dubbo.service.BeanService;
import org.apache.dubbo.config.annotation.Service;

import java.util.ArrayList;
import java.util.List;

@Service
public class BeanServiceImpl implements BeanService {


    @Override
    public List<Bean> getBean() {

        Bean bean = new Bean();

        bean.setId(1);
        bean.setPassword("222");
        bean.setTargetId("111111");
        bean.setUsername("chenxin");

        List<Bean> retList = new ArrayList<>();
        retList.add(bean);
        return retList;
    }

    @Override
    public void resolveBean(Bean bean) {
        System.out.println(bean.toString());
    }


}
